import request from '@/utils/request'

// 查询宿舍基础信息列表
export function listDormitory(query) {
  return request({
    url: '/biz/dormitory/list',
    method: 'get',
    params: query
  })
}

// 查询宿舍基础信息详细
export function getDormitory(dormitoryId) {
  return request({
    url: '/biz/dormitory/' + dormitoryId,
    method: 'get'
  })
}

// 新增宿舍基础信息
export function addDormitory(data) {
  return request({
    url: '/biz/dormitory',
    method: 'post',
    data: data
  })
}

// 修改宿舍基础信息
export function updateDormitory(data) {
  return request({
    url: '/biz/dormitory',
    method: 'put',
    data: data
  })
}

// 删除宿舍基础信息
export function delDormitory(dormitoryId) {
  return request({
    url: '/biz/dormitory/' + dormitoryId,
    method: 'delete'
  })
}